 

#region Copyright Statement
//////////////////////////////////////////////
//	ORMAC
//  By: Ali Ghomi (2011)
//////////////////////////////////////////////
#endregion

#region using
using System;
using System.Collections.Generic;
using ORMAC;
using ORMAC.Attributes;
using System.Runtime.Serialization;
#endregion

namespace Test
{
	/// <summary>
	/// Auto generated class by ORMAC from Employees table
	/// </summary>
	[Table("Employees")]
	[DataContract]
	public class OEmployees
	{
		/// <summary>
		/// Auto generated property by ORMAC from EmployeeID column
		/// </summary>		
		[PrimaryKey]
		[Field("EmployeeID")]
		[DataMember]
		public int EmployeeID{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from LastName column
		/// </summary>		
		[Field("LastName")]
		[DataMember]
		public string LastName{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from FirstName column
		/// </summary>		
		[Field("FirstName")]
		[DataMember]
		public string FirstName{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from Title column
		/// </summary>		
		[Field("Title")]
		[DataMember]
		public string Title{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from TitleOfCourtesy column
		/// </summary>		
		[Field("TitleOfCourtesy")]
		[DataMember]
		public string TitleOfCourtesy{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from BirthDate column
		/// </summary>		
		[Field("BirthDate")]
		[DataMember]
		public DateTime BirthDate{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from HireDate column
		/// </summary>		
		[Field("HireDate")]
		[DataMember]
		public DateTime HireDate{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from Address column
		/// </summary>		
		[Field("Address")]
		[DataMember]
		public string Address{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from City column
		/// </summary>		
		[Field("City")]
		[DataMember]
		public string City{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from Region column
		/// </summary>		
		[Field("Region")]
		[DataMember]
		public string Region{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from PostalCode column
		/// </summary>		
		[Field("PostalCode")]
		[DataMember]
		public string PostalCode{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from Country column
		/// </summary>		
		[Field("Country")]
		[DataMember]
		public string Country{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from HomePhone column
		/// </summary>		
		[Field("HomePhone")]
		[DataMember]
		public string HomePhone{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from Extension column
		/// </summary>		
		[Field("Extension")]
		[DataMember]
		public string Extension{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from Photo column
		/// </summary>		
		[Field("Photo")]
		[DataMember]
		public Byte [] Photo{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from Notes column
		/// </summary>		
		[Field("Notes")]
		[DataMember]
		public string Notes{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from ReportsTo column
		/// </summary>		
		[Field("ReportsTo")]
		[DataMember]
		public int ReportsTo{
			get;
			set;
		}
		/// <summary>
		/// Auto generated property by ORMAC from PhotoPath column
		/// </summary>		
		[Field("PhotoPath")]
		[DataMember]
		public string PhotoPath{
			get;
			set;
		}
		/// <summary>
		/// Auto generated class property by ORMAC using
		///EmployeeID as primary key and ReportsTo as foreign key in  Employees table
		/// </summary>				
		[DataMember]
		[Join(ParentCol="EmployeeID",ChildCol="ReportsTo")]
		public List<OEmployees> Employeess{
			get;
			set;
		}
		/// <summary>
		/// Auto generated class property by ORMAC using
		///EmployeeID as primary key and EmployeeID as foreign key in  Orders table
		/// </summary>				
		[DataMember]
		[Join(ParentCol="EmployeeID",ChildCol="EmployeeID")]
		public List<OOrders> Orderss{
			get;
			set;
		}
		[DataMember]
		[LinkTable(LinkTableName="EmployeeTerritories", ParentCol="EmployeeID",LinkTableParentCol="EmployeeID",LinkTableChildCol="TerritoryID",ChildCol="TerritoryID")]		
		public List<OTerritories> Territoriess{
			get;
			set;
		}

	}
}
